{template 'common/header'}
<ul class="nav nav-tabs">
	<li {if $operation == 'display'}class="active"{/if}><a href="{php echo create_url('site/module/credit', array('name' => 'hlzonyu', 'op' => 'display'));}">管理</a></li>
</ul>
{if $operation == 'display'}
<div class="main">
	<div style="padding:15px;">
		<table class="table table-hover">
			<thead class="navbar-inner">
				<tr>
					<th style="width:50px;">姓名</th>
					<th style="width:100px;">手机</th>
					<th style="width:200px;">地址</th>
					<th style="width:100px;">时间</th>
					<th style="min-width:150px;">奖品名称</th>
					<th style="width:50px;">价格</th>
					<th style="width:30px;">消耗积分</th>
					<th style="width:100px;">剩余积分</th>
					<th style="text-align:right; min-width:60px;">操作</th>
				</tr>
			</thead>
			<tbody>
				{loop $list $item}
				<tr>
					<td>{$fans[$item['from_user']]['realname']}</td>
					<td>{$fans[$item['from_user']]['mobile']}</td>
					<td>{$fans[$item['from_user']]['residedist']}</td>
					<td>{php echo date('Y-m-d H:i:s', $item['createtime'])}</td>
					<td>{$item['title']}</td>
					<td>{$item['price']}</td>
					<td>{$item['credit_cost']}</td>
					<td>{$fans[$item['from_user']]['credit1']}</td>
					<td style="text-align:right;">
						<a href="{php echo create_url('site/module/credit', array('name' => 'hlzonyu', 'id' => $item['id'], 'op' => 'delete'))}" onclick="return confirm('此操作不可恢复，确认删除？');return false;" title="删除" class="btn btn-small"><i class="icon-remove"></i></a>
					</td>
				</tr>
				{/loop}
			</tbody>
			<!--tr>
				<td colspan="8">
					<input name="token" type="hidden" value="{$_W['token']}" />
					<input type="submit" class="btn btn-primary" name="submit" value="提交" />
				</td>
			</tr-->
		</table>
	</div>
</div>
{/if}
{template 'common/footer'}
